Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix constructor syntax #66

Merged
merged 1 commit into from
Nov 4, 2024
Merged

fix constructor syntax #66

merged 1 commit into from
Nov 4, 2024

Conversation

xuwei-k
Copy link
Contributor

@xuwei-k xuwei-k commented Oct 20, 2024

prepare Scala 3, sbt 2.x cross build

Welcome to Scala 2.13.15 (OpenJDK 64-Bit Server VM, Java 21.0.4).
Type in expressions for evaluation. Or try :help.

scala> class A {
     |   def this(x: Int) { this() }
     | }
         def this(x: Int) { this() }
                         ^
On line 2: warning: procedure syntax is deprecated for constructors: add `=`, as in method definition [quickfixable]
Welcome to Scala 3.3.4 (21.0.4, Java OpenJDK 64-Bit Server VM).
Type in expressions for evaluation. Or try :help.
                                                                                                                                             
scala> class A {
     |   def this(x: Int) { this() }
-- [E040] Syntax Error: --------------------------------------------------------
2 |  def this(x: Int) { this() }
  |                   ^
  |                   '=' expected, but '{' found

@unkarjedy
Copy link
Member

Thanks!

@unkarjedy unkarjedy merged commit 5986c47 into JetBrains:master Nov 4, 2024
1 check passed
@xuwei-k xuwei-k deleted the patch-1 branch November 4, 2024 21:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants